#ifndef MYWIDGET_H
#define MYWIDGET_H

#include <QWidget>
#include <QtQuickWidgets/QQuickWidget>
#include <QSystemTrayIcon>

#ifdef Q_OS_WIN
#pragma comment(lib, "user32.lib")
#include <qt_windows.h>
#endif

#include "querykeythread.h"

class MyWidget : public QWidget
{
    Q_OBJECT
public:
    explicit MyWidget(QWidget *parent = nullptr);
    void setSystemMenu();

signals:
    void notifyMsg(int mx, int my);
    void notifyMousePos(int mx, int my);

public slots:
    void queryResult(QString name);
    void mousePointChanged(int x, int y);
    void systemExit(bool b);

private:
    QQuickWidget* m_view;
//    QueryKeyThread* m_thread;
    QSystemTrayIcon *trayIcon;
};

#endif // MYWIDGET_H
